package com.xiaoka.ins.corp.api.gpic.dto;

import java.util.ArrayList;
import java.util.List;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlSchemaType;
import javax.xml.bind.annotation.XmlType;
import javax.xml.bind.annotation.XmlValue;

@XmlAccessorType(XmlAccessType.FIELD)
@XmlRootElement(name="Response")
public class ResponseElementGPIC {

    @XmlElement(name = "TagsList", required = true)
    protected TagsList tagsList;

    @XmlElement(name = "Order")
    protected Order order;
    
    public TagsList getTagsList() {
        return tagsList;
    }

    public void setTagsList(TagsList value) {
        this.tagsList = value;
    }

    public Order getOrder() {
		return order;
	}

	public void setOrder(Order order) {
		this.order = order;
	}

	@XmlAccessorType(XmlAccessType.FIELD)
    @XmlType(name = "", propOrder = {
        "tags"
    })
    public static class TagsList {

        @XmlElement(name = "Tags", required = true)
        protected List<Tags> tags;

        public List<Tags> getTags() {
			return tags;
		}


		public void setTags(List<Tags> tags) {
			this.tags = tags;
		}

		@XmlAccessorType(XmlAccessType.FIELD)
        @XmlType(name = "", propOrder = {
            "tag"
        })
        public static class Tags {

			@XmlElement(name = "Tag")
            protected List<Tag> tag;
            @XmlAttribute(name = "type")
            protected String type;

            public List<Tag> getTag() {
                if (tag == null) {
                    tag = new ArrayList<Tag>();
                }
                return this.tag;
            }

            public String getType() {
                return type;
            }

            public void setType(String value) {
                this.type = value;
            }


            @XmlAccessorType(XmlAccessType.FIELD)
            @XmlType(name = "", propOrder = {
                "definition"
            })
            public static class Tag {

                @XmlElement(name = "Definition")
                protected List<Definition> definition;

                public List<Definition> getDefinition() {
					return definition;
				}

				public void setDefinition(List<Definition> definition) {
					this.definition = definition;
				}

				@XmlAccessorType(XmlAccessType.FIELD)
                @XmlType(name = "", propOrder = {
                    "value"
                })
                public static class Definition {

                	@XmlAttribute(name = "name")
                	protected String name;
                    @XmlValue
                    protected String value;
                    
                    public Definition() {}

					public Definition(String name, String value) {
						this.name = name;
						this.value = value;
					}

					public String getValue() {
                        return value;
                    }

                    public void setValue(String value) {
                        this.value = value;
                    }

                    public String getName() {
                        return name;
                    }

                    public void setName(String value) {
                        this.name = value;
                    }

                }

            }

        }

    }

    @XmlAccessorType(XmlAccessType.FIELD)
    @XmlType(name = "", propOrder = {
        "tbOrderId",
        "orderId",
        "premium",
        "payNo",
        "paymentUrl",
        "payOutTime",
        "subOrderList"
    })
    public static class Order {

        @XmlElement(name = "TBOrderId")
        protected String tbOrderId;
        @XmlElement(name = "OrderId")
        protected String orderId;
        @XmlElement(name = "Premium")
        protected String premium;
        @XmlElement(name = "PayNo", required = true)
        protected String payNo;
        @XmlElement(name = "PaymentUrl", required = true)
        @XmlSchemaType(name = "anyURI")
        protected String paymentUrl;
        @XmlElement(name = "PayOutTime", required = true)
        protected String payOutTime;
        @XmlElement(name = "SubOrderList", required = true)
        protected SubOrderList subOrderList;

        public String getTbOrderId() {
			return tbOrderId;
		}

		public void setTbOrderId(String tbOrderId) {
			this.tbOrderId = tbOrderId;
		}
		
        public String getOrderId() {
			return orderId;
		}

		public void setOrderId(String orderId) {
			this.orderId = orderId;
		}

		public String getPremium() {
            return premium;
        }

        
        public void setPremium(String value) {
            this.premium = value;
        }

       
        public String getPayNo() {
            return payNo;
        }

      
        public void setPayNo(String value) {
            this.payNo = value;
        }

        public String getPaymentUrl() {
			return paymentUrl;
		}

		public void setPaymentUrl(String paymentUrl) {
			this.paymentUrl = paymentUrl;
		}

		public String getPayOutTime() {
            return payOutTime;
        }

        public void setPayOutTime(String value) {
            this.payOutTime = value;
        }

        public SubOrderList getSubOrderList() {
            return subOrderList;
        }

        public void setSubOrderList(SubOrderList value) {
            this.subOrderList = value;
        }


        @XmlAccessorType(XmlAccessType.FIELD)
        @XmlType(name = "", propOrder = {
            "subOrder"
        })
        public static class SubOrderList {

            @XmlElement(name = "SubOrder", required = true)
            protected List<SubOrder> subOrder;

            public List<SubOrder> getSubOrder() {
				return subOrder;
			}

			public void setSubOrder(List<SubOrder> subOrder) {
				this.subOrder = subOrder;
			}

			@XmlAccessorType(XmlAccessType.FIELD)
            @XmlType(name = "", propOrder = {
                "tbOrderId",
                "itemId",
                "premium",
                "proposalNo",
                "policyNo"
            })
            public static class SubOrder {

                @XmlElement(name = "TBOrderId")
                protected String tbOrderId;
                @XmlElement(name = "ItemId")
                protected String itemId;
                @XmlElement(name = "Premium")
                protected String premium;
                @XmlElement(name = "ProposalNo")
                protected String proposalNo;
                @XmlElement(name = "PolicyNo")
                protected String policyNo;
                @XmlAttribute(name = "type")
                protected String type;

                public SubOrder() {}
                
                public SubOrder(String tbOrderId, String itemId,
						String premium, String proposalNo, String type) {
					this.tbOrderId = tbOrderId;
					this.itemId = itemId;
					this.premium = premium;
					this.proposalNo = proposalNo;
					this.type = type;
				}

                public String getTbOrderId() {
					return tbOrderId;
				}

				public void setTbOrderId(String tbOrderId) {
					this.tbOrderId = tbOrderId;
				}

				public String getPolicyNo() {
					return policyNo;
				}

				public void setPolicyNo(String policyNo) {
					this.policyNo = policyNo;
				}

				public String getItemId() {
                    return itemId;
                }

                public void setItemId(String value) {
                    this.itemId = value;
                }

                public String getPremium() {
                    return premium;
                }

                public void setPremium(String value) {
                    this.premium = value;
                }

                public String getProposalNo() {
                    return proposalNo;
                }

                public void setProposalNo(String value) {
                    this.proposalNo = value;
                }

                public String getType() {
                    return type;
                }

                public void setType(String value) {
                    this.type = value;
                }

            }
        }
	}
}